package com.krstin.designpattern.singleResponsibility;

public class SingleResponseibility1 {

    public static void main(String[] args) {
        Vehicle vehicle = new Vehicle();
        vehicle.run("摩托车");
        vehicle.run("汽车");
        vehicle.run("飞机");
    }

}


class  Vehicle {

    public void run(String Vehicle) {
        System.out.println(Vehicle + "在公路上运行");
    }

}